package com.jichangxiu.server.platform.entity.map;

import com.jichangxiu.server.platform.entity.dto.PlatformConfigQueryDto;
import com.jichangxiu.server.platform.entity.po.PlatformConfig;
import com.jichangxiu.server.platform.entity.vo.PlatformConfigAddVo;
import com.jichangxiu.server.platform.entity.vo.PlatformConfigEditVo;
import com.jichangxiu.server.platform.entity.vo.PlatformConfigQueryVo;
import org.mapstruct.Builder;
import org.mapstruct.Mapper;
import org.mapstruct.factory.Mappers;

import java.util.List;

/**
 * PlatformConfigBasic:
 *
 * @author Jcx
 * @create 2023-03-19 8:41
 */
@Mapper(builder = @Builder(disableBuilder = true))
public interface PlatformConfigBasic {

    public PlatformConfigBasic INSTANCE = Mappers.getMapper(PlatformConfigBasic.class);

    /**
     * 转换 PlatformDictType
     *
     * @param platformConfigAddVo 视图对象
     * @return 数据库对象
     */
    public PlatformConfig toPlatformConfig(PlatformConfigAddVo platformConfigAddVo);

    /**
     * 转换 PlatformDictType
     *
     * @param platformConfigEditVo 视图对象
     * @return 数据库对象
     */
    public PlatformConfig toPlatformConfig(PlatformConfigEditVo platformConfigEditVo);

    /**
     * 转换 PlatformDictType
     *
     * @param platformConfigQueryVo 视图对象
     * @return 数据库对象
     */
    public PlatformConfig toPlatformConfig(PlatformConfigQueryVo platformConfigQueryVo);

    /**
     * 转换 PlatformConfigQueryDto
     *
     * @param platformConfig 数据库对象
     * @return 传输对象
     */
    public PlatformConfigQueryDto toPlatformConfigQueryDto(PlatformConfig platformConfig);

    /**
     * 转换 PlatformConfigQueryDto 列表
     *
     * @param platformConfigList 数据库对象列表
     * @return 传输对象列表
     */
    public List<PlatformConfigQueryDto> toPlatformConfigQueryDtoList(List<PlatformConfig> platformConfigList);

}
